<?php

namespace app\models;

use Yii;

/**
 * This is the model class for table "integral_good".
 *
 * @property int $id
 * @property string $good_name
 * @property string $good_img
 * @property int $good_num
 * @property double $good_price
 * @property int $good_integral
 * @property int $update_time
 * @property int $create_time
 */
class IntegralGood extends \yii\db\ActiveRecord
{
    /**
     * {@inheritdoc}
     */
    public static function tableName()
    {
        return 'integral_good';
    }

    /**
     * {@inheritdoc}
     */
    public function rules()
    {
        return [
            [['good_name', 'good_img', 'good_num', 'good_price', 'good_integral', 'update_time', 'create_time'], 'required'],
            [['good_num', 'good_integral', 'update_time', 'create_time'], 'integer'],
            [['good_price'], 'number'],
            [['good_name'], 'string', 'max' => 64],
            [['good_img'], 'string', 'max' => 128],
        ];
    }

    /**
     * {@inheritdoc}
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'good_name' => 'Good Name',
            'good_img' => 'Good Img',
            'good_num' => 'Good Num',
            'good_price' => 'Good Price',
            'good_integral' => 'Good Integral',
            'update_time' => 'Update Time',
            'create_time' => 'Create Time',
        ];
    }
}
